<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.6"/>
<title>GraphPaths:  File sorgente backup/grafo.h</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">GraphPaths
   &#160;<span id="projectnumber">1</span>
   </div>
   <div id="projectbrief">Creazione di grafi e calcolo dei percorsi minimi</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generato da Doxygen 1.8.6 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Cerca');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Pagina&#160;Principale</span></a></li>
      <li><a href="annotated.html"><span>Classi</span></a></li>
      <li class="current"><a href="files.html"><span>File</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Cerca" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>Elenco&#160;dei&#160;file</span></a></li>
      <li><a href="globals.html"><span>Elementi&#160;dei&#160;file</span></a></li>
    </ul>
  </div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>Tutto</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classi</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>File</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Funzioni</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variabili</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Ridefinizioni di tipo (typedef)</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Definizioni</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Pagine</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_0b457ace402ca7986e274a9663e8d868.html">backup</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">grafo.h</div>  </div>
</div><!--header-->
<div class="contents">
<a href="backup_2grafo_8h.html">Vai alla documentazione di questo file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="preprocessor">#ifndef GRAFO_H</span></div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="preprocessor"></span><span class="preprocessor">#define GRAFO_H</span></div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="preprocessor">#include &lt;iostream&gt;</span></div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="preprocessor">#include &lt;fstream&gt;</span></div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="preprocessor">#include &lt;cassert&gt;</span></div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;</div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="backup_2nodo_8h.html">nodo.h</a>&quot;</span></div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="backup_2arco_8h.html">arco.h</a>&quot;</span></div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="preprocessor">#include &lt;glib.h&gt;</span></div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;</div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="keyword">using namespace </span>std;</div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;</div>
<div class="line"><a name="l00014"></a><span class="lineno"><a class="line" href="classgrafo.html">   14</a></span>&#160;<span class="keyword">class </span><a class="code" href="classgrafo.html">grafo</a> : <span class="keyword">public</span> <a class="code" href="classelemento__ui.html">elemento_ui</a></div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;{</div>
<div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;    <span class="keyword">public</span>:</div>
<div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;    <a class="code" href="classgrafo.html">grafo</a>();</div>
<div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;    <span class="keyword">virtual</span> ~<a class="code" href="classgrafo.html">grafo</a>();</div>
<div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160;</div>
<div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160;    <span class="keywordtype">void</span> inizializza();</div>
<div class="line"><a name="l00025"></a><span class="lineno">   25</span>&#160;</div>
<div class="line"><a name="l00031"></a><span class="lineno">   31</span>&#160;    <a class="code" href="classelemento__ui.html">elemento_ui</a>* find_by_xy(gdouble x, gdouble y);</div>
<div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160;</div>
<div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160;    <span class="keywordtype">void</span> seleziona(<a class="code" href="classnodo.html">nodo</a> *<a class="code" href="classnodo.html">nodo</a>);</div>
<div class="line"><a name="l00037"></a><span class="lineno">   37</span>&#160;</div>
<div class="line"><a name="l00043"></a><span class="lineno">   43</span>&#160;    <span class="keywordtype">void</span> seleziona(gdouble x, gdouble y);</div>
<div class="line"><a name="l00044"></a><span class="lineno">   44</span>&#160;</div>
<div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160;    nodo* get_selezionato();</div>
<div class="line"><a name="l00049"></a><span class="lineno">   49</span>&#160;</div>
<div class="line"><a name="l00055"></a><span class="lineno">   55</span>&#160;     nodo* aggiungi_nodo(gdouble x, gdouble y);</div>
<div class="line"><a name="l00056"></a><span class="lineno">   56</span>&#160;</div>
<div class="line"><a name="l00061"></a><span class="lineno">   61</span>&#160;    <span class="keywordtype">void</span> aggiungi_arco(nodo* destinazione);</div>
<div class="line"><a name="l00062"></a><span class="lineno">   62</span>&#160;        </div>
<div class="line"><a name="l00067"></a><span class="lineno">   67</span>&#160;    <span class="keywordtype">void</span> lmb_premuto(gdouble x, gdouble y);</div>
<div class="line"><a name="l00068"></a><span class="lineno">   68</span>&#160;    </div>
<div class="line"><a name="l00071"></a><span class="lineno">   71</span>&#160;    <span class="keywordtype">void</span> lmb_rilasciato();        </div>
<div class="line"><a name="l00072"></a><span class="lineno">   72</span>&#160;    </div>
<div class="line"><a name="l00076"></a><span class="lineno">   76</span>&#160;    gboolean is_dragging();     </div>
<div class="line"><a name="l00080"></a><span class="lineno"><a class="line" href="classgrafo.html#a385f1046154a45cd718820781dcfa0e1">   80</a></span>&#160;    GSList* <a class="code" href="classgrafo.html#a385f1046154a45cd718820781dcfa0e1">get_nodi</a>() { <span class="keywordflow">return</span> nodi; }</div>
<div class="line"><a name="l00081"></a><span class="lineno">   81</span>&#160;</div>
<div class="line"><a name="l00085"></a><span class="lineno"><a class="line" href="classgrafo.html#a775d29c0417639270e8df7fbe6cfe514">   85</a></span>&#160;    GSList* <a class="code" href="classgrafo.html#a775d29c0417639270e8df7fbe6cfe514">get_archi</a>() {<span class="keywordflow">return</span> lista_adiacenze; }</div>
<div class="line"><a name="l00086"></a><span class="lineno">   86</span>&#160;</div>
<div class="line"><a name="l00090"></a><span class="lineno">   90</span>&#160;    <span class="keywordtype">void</span> prepara();</div>
<div class="line"><a name="l00091"></a><span class="lineno">   91</span>&#160;</div>
<div class="line"><a name="l00095"></a><span class="lineno">   95</span>&#160;    guint get_numero_nodi();</div>
<div class="line"><a name="l00096"></a><span class="lineno">   96</span>&#160;    </div>
<div class="line"><a name="l00100"></a><span class="lineno">  100</span>&#160;    <span class="keywordtype">void</span> salva(<span class="keyword">const</span> <span class="keywordtype">char</span>* file);</div>
<div class="line"><a name="l00101"></a><span class="lineno">  101</span>&#160;    </div>
<div class="line"><a name="l00106"></a><span class="lineno">  106</span>&#160;    <span class="keywordtype">void</span> <a class="code" href="backup_2main_8cc.html#a2695afd8cb4242971912f7cce63c3f27">carica</a>(<span class="keyword">const</span> <span class="keywordtype">char</span>* file);</div>
<div class="line"><a name="l00107"></a><span class="lineno">  107</span>&#160;    </div>
<div class="line"><a name="l00108"></a><span class="lineno">  108</span>&#160;    <span class="keyword">virtual</span> <span class="keywordtype">void</span> draw(cairo_t* &amp;cr);</div>
<div class="line"><a name="l00109"></a><span class="lineno">  109</span>&#160;    <span class="keyword">virtual</span> <span class="keywordtype">void</span> update(gdouble x, gdouble y);</div>
<div class="line"><a name="l00110"></a><span class="lineno">  110</span>&#160;</div>
<div class="line"><a name="l00111"></a><span class="lineno">  111</span>&#160;    <span class="keyword">protected</span>:</div>
<div class="line"><a name="l00112"></a><span class="lineno">  112</span>&#160;    <span class="keyword">private</span>:</div>
<div class="line"><a name="l00113"></a><span class="lineno">  113</span>&#160;        nodo* selezionato; </div>
<div class="line"><a name="l00114"></a><span class="lineno">  114</span>&#160;        <a class="code" href="classarco.html">arco</a>* arco_selezionato; </div>
<div class="line"><a name="l00115"></a><span class="lineno">  115</span>&#160;        guint indice_corrente; </div>
<div class="line"><a name="l00116"></a><span class="lineno">  116</span>&#160;</div>
<div class="line"><a name="l00117"></a><span class="lineno">  117</span>&#160;        GSList* nodi; </div>
<div class="line"><a name="l00118"></a><span class="lineno">  118</span>&#160;        GSList* lista_adiacenze; </div>
<div class="line"><a name="l00119"></a><span class="lineno">  119</span>&#160;</div>
<div class="line"><a name="l00120"></a><span class="lineno">  120</span>&#160;        nodo* find_by_index(guint indice); </div>
<div class="line"><a name="l00121"></a><span class="lineno">  121</span>&#160;        <span class="keywordtype">void</span> deseleziona_nodi(); </div>
<div class="line"><a name="l00122"></a><span class="lineno">  122</span>&#160;        <span class="keywordtype">void</span> carica_elemento(istream &amp;ifs); </div>
<div class="line"><a name="l00123"></a><span class="lineno">  123</span>&#160;        gboolean is_lmb_pressed; </div>
<div class="line"><a name="l00124"></a><span class="lineno">  124</span>&#160;        gdouble mouse_origin_x; </div>
<div class="line"><a name="l00125"></a><span class="lineno">  125</span>&#160;        gdouble mouse_origin_y; </div>
<div class="line"><a name="l00126"></a><span class="lineno">  126</span>&#160;};</div>
<div class="line"><a name="l00127"></a><span class="lineno">  127</span>&#160;</div>
<div class="line"><a name="l00128"></a><span class="lineno">  128</span>&#160;<span class="preprocessor">#endif // GRAFO_H</span></div>
<div class="ttc" id="classgrafo_html"><div class="ttname"><a href="classgrafo.html">grafo</a></div><div class="ttdef"><b>Definition:</b> grafo.h:14</div></div>
<div class="ttc" id="classelemento__ui_html"><div class="ttname"><a href="classelemento__ui.html">elemento_ui</a></div><div class="ttdef"><b>Definition:</b> elemento_ui.h:7</div></div>
<div class="ttc" id="backup_2arco_8h_html"><div class="ttname"><a href="backup_2arco_8h.html">arco.h</a></div></div>
<div class="ttc" id="classgrafo_html_a385f1046154a45cd718820781dcfa0e1"><div class="ttname"><a href="classgrafo.html#a385f1046154a45cd718820781dcfa0e1">grafo::get_nodi</a></div><div class="ttdeci">GSList * get_nodi()</div><div class="ttdef"><b>Definition:</b> grafo.h:80</div></div>
<div class="ttc" id="classarco_html"><div class="ttname"><a href="classarco.html">arco</a></div><div class="ttdef"><b>Definition:</b> arco.h:7</div></div>
<div class="ttc" id="backup_2main_8cc_html_a2695afd8cb4242971912f7cce63c3f27"><div class="ttname"><a href="backup_2main_8cc.html#a2695afd8cb4242971912f7cce63c3f27">carica</a></div><div class="ttdeci">void carica(GtkWidget *widget)</div><div class="ttdef"><b>Definition:</b> main.cc:106</div></div>
<div class="ttc" id="classgrafo_html_a775d29c0417639270e8df7fbe6cfe514"><div class="ttname"><a href="classgrafo.html#a775d29c0417639270e8df7fbe6cfe514">grafo::get_archi</a></div><div class="ttdeci">GSList * get_archi()</div><div class="ttdef"><b>Definition:</b> grafo.h:85</div></div>
<div class="ttc" id="classnodo_html"><div class="ttname"><a href="classnodo.html">nodo</a></div><div class="ttdef"><b>Definition:</b> nodo.h:10</div></div>
<div class="ttc" id="backup_2nodo_8h_html"><div class="ttname"><a href="backup_2nodo_8h.html">nodo.h</a></div></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generato Mar 1 Lug 2014 08:14:03 per GraphPaths da &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.6
</small></address>
</body>
</html>
